package com.ynding.spring.idea.ddd.common.aax.bo;

import lombok.Getter;

/**
 * 返回码
 * @author ynding
 */
public enum ResponseCode implements IResponseCode {
    /**
     *
     */
    SUCCESS_CODE(200, ""),
    PARAM_ERROR_CODE(400, "param_error"),
    LIMIT_ERROR_CODE(401, "limit_error"),
    TOKEN_TIMEOUT_CODE(402, "token_expired"),
    NO_AUTH_CODE(403, "forbidden"),
    NOT_FOUND(404, "not_found"),
    SERVER_ERROR_CODE(500, "server_error"),
    USER_AlREAD_EXIST_EXCEPTION(401,"用户已经存在"),
    DOWNGRADE(406, "downgrade");

    @Getter
    private int code;
    @Getter
    private String message;

    private ResponseCode(int code, String message) {
        this.code = code;
        this.message = message;
    }

}
